import zipfile

zFile = zipfile.ZipFile("e:/study/python/xixi/ex1/abc.zip")
pwd = 1
while True:
    try:
        zFile.extractall(pwd=str(pwd).encode())
        print("解密成功，密码是：", pwd)
        break
    except:
        print("正在进行尝试密码", pwd, "...")
        pwd = pwd + 1
